package com.bachelor.community.mapper;

import com.bachelor.community.model.entity.Tag;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface TagMapper extends BaseMapper<Tag> {
    @Select("select tag.* from tag where tag.name like CONCAT('%', #{keyword}, '%')")
    List<Tag> listTagsByKeyword(String keyword);
}
